//
//  Calling.h
//  ZhumuSDKSample
//
//  Copyright 2006-2015 SUIRUI Co., Ltd. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <ZhumuSDK/ZhumuSDK.h>
#import "Meeting.h"

#if __has_feature(objc_arc)
    #define ZM_AUTORELEASE(exp) exp
    #define ZM_RELEASE(exp) exp
    #define ZM_RETAIN(exp) exp
#else
    #define ZM_AUTORELEASE(exp) [exp autorelease]
    #define ZM_RELEASE(exp) [exp release]
    #define ZM_RETAIN(exp) [exp retain]
#endif

typedef void (^CALL_SUCCESS)(Meeting *meeting);
typedef void (^CALL_FAILURE)(NSString *error);

@interface Calling : NSObject
+(void)startCall:(Meeting *)info delegate:(id<ZhumuSDKMeetingServiceDelegate>)delegate success:(CALL_SUCCESS)success failure:(CALL_FAILURE)failure;
@end

/**
 *  需要先进行服务端数据请求的呼叫类
 */
@interface RequestCalling : Calling <NSURLConnectionDelegate>
@end

@interface InstantCalling : RequestCalling
@end

@interface JoinCalling : Calling
@end

@interface ScheduledCalling : RequestCalling
@end